package com.fymxy.question_bank_management.mapper;

import com.fymxy.question_bank_management.pojo.Keyword;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Component;
import java.util.List;

import org.apache.ibatis.annotations.*;


@Component
@Mapper
public interface KeywordMapper {

    @Insert("insert into keyword (problem_no,keyword_content) values " +
            "(#{problemNo},#{keywordContent})")
    int insert(Keyword record);

    int insertSelective(Keyword record);


    @Delete("delete from keyword where problem_no = #{id}")
    int deleteKeywordByProNo(Integer id);
    @Select("select distinct keyword_content from keyword")
    List<String> getAllKeywordContent();

}